
<div id="inside_banner">
	<?php echo $this->element('layouts/inside_banner'); ?>
</div>
<div class="block">
	<div class="title">Kết quả tìm kiếm</div>
	<div class="text"><strong style="color:#ff0000"><?php echo $result; ?></strong></div>
	<?php if (!empty($products)) { ?>
	<div class="items">
    	<table width="100%" cellpadding="0" cellspacing="0">
			<?php
			$numRows = ceil(count($products) / 2);
			$i = 0;
			for ($rows = 0; $rows < $numRows; $rows++) {
				?>
				<tr>
					<?php
					for ($cols = 0; $cols < 2; $cols++) {
						?>
						<td valign="top" width="50%">
							<?php
							if (isset($products[$i])) {
								?>
								<div class="list">

									<div class="left-list">
									<?php
										echo $html->link(
											$html->image("products/{$products[$i]['Product']['img']}",
													array(
														'alt'		=> $products[$i]['Product']['name_'.$lang],
														'class'		=> 'product',
														'width'		=> '90px',
														'height'	=> '90px',
														'align'		=> 'center'
													)
											),
											array(
												'plugin'	=> NULL,
												'controller' => 'product',
												'action' => 'detail',$products[$i]['Product']['id'],Inflector::slug($products[$i]['Product']['name_'.$lang])
											),
											array(
												'escape' => false
											)
										);
										?>
									</div>
									<div class="right-list">
										<table>
											<tr>
												<td width="37%"><?php echo __('Model', true); ?></td>
												<td>: <strong style="color:green">
												<?php
													echo $html->link($products[$i]['Product']['model'],
														array(
															'plugin'	=> NULL,
															'controller' => 'product',
															'action' => 'detail',$products[$i]['Product']['id'],Inflector::slug($products[$i]['Product']['name_'.$lang])
														),
														array(
															'style' => 'color:green'
														)
													);
												?><strong></td>
											</tr>
											<tr>
												<td width="37%"><?php echo __('Xuất xứ', true); ?></td>
												<td>: <strong><?php echo$products[$i]['Product']['sanxuat']; ?></strong></td>
											</tr>
											<tr>
												<td width="37%"><?php echo __('Kích thước', true); ?></td>
												<td>: <strong><?php echo $products[$i]['Product']['kichthuoc']; ?></strong></td>
											</tr>
										</table>
									</div>
									<br clear="all" />
								</div>
								<?php
							} else {
								echo ('&nbsp;&nbsp;&nbsp;');
							}
							?>
						</td>
						<?php
						$i++;
					}
					?>
				</tr>
				<?php
			}
			?>
		</table>
	</div>
	<?php echo $this->element('layouts/page_nav'); ?>
	<?php  } ?>
</div>


